package com.azier.kapacitor.script.method;

import com.azier.kapacitor.script.arg.OriginalArg;

import java.util.ArrayList;

/**
* 1 * @Author: luoj
* 2 * @Date: 2019/11/8 11:27
* 3
*/
public class FlushInterval extends AbstractMethod {
    private static final String name = "flushInterval";
    /**
    Write points to InfluxDB after interval even if buffer is not full. Default: 10s
    **/
    /**
    即使缓冲区未满，也要在间隔后将点写入InfluxDB。默认值：10秒
    **/
    public FlushInterval(long interval, String durationLiteral) {
        super(new ArrayList<>(), name);
        //
        this.args.add(new OriginalArg(interval + durationLiteral));

    }
}
